<!--ueditor S-->
<script type="text/javascript" src="{{$smarty.const.__SHARE__}}plug/ueditor/ueditor.config.js?2"></script>
<script type="text/javascript" src="{{$smarty.const.__SHARE__}}plug/ueditor/ueditor.all.min.js"></script>
<script type="text/javascript" src="{{$smarty.const.__SHARE__}}plug/ueditor/lang/zh-cn/zh-cn.js"></script>

<!--ueditor E-->
<script type="text/javascript">
//实例化编辑器
//建议使用工厂方法getEditor创建和引用编辑器实例，如果在某个闭包下引用该编辑器，直接调用UE.getEditor('editor')就能拿到相关的实例
if($('.editor').length>0){
	var ue = new Array();
	$('.editor').each(function(n){
		var ue_id = $(this).attr("id");
		if(ue_id!=undefined){
			if($(this).attr("style")!=undefined){
				ue[ue_id] = UE.getEditor(ue_id);
			}else{
				ue[ue_id] = UE.getEditor(ue_id,{initialFrameHeight:300,initialFrameWidth:720});
			}
		}
	});
	$("form").submit(function(){
		$('.editor').each(function(n){
			var ue_id = $(this).attr("id");
			if(ue_id!=undefined){
				UE.getEditor(ue_id).execCommand('source');
				UE.getEditor(ue_id).execCommand('source');
			}
		});
	});
}


</script>